const routes = [
  {
    path: '/financialAffairs',
    name: 'financialAffairs',
    redirect: '/financialAffairs/accountRecords/list',
    meta: {
      name: '财务' ,
      icon: '',
      pickIcon: '',
      order: 3,
      crumbs: ['财务']
    },
    children: [
      {
        path: 'accountRecords',
        name: 'accountRecords',
        meta: {
          name: '账目记录',
          crumbs: ['财务','账目记录'],
        },
        children: [
          {
            path: 'list',
            name: 'incomeAndExpanse',
            meta: {
              name: '收支记账',
              href: '/financialAffairs/accountRecords/list',
              crumbs: ['财务','账目记录','收支记账'],
            },
            component: () => import('@/view/page/FinancialAffairs/AccountRecords/List.vue')
          },
          {
            path: 'chart',
            name: 'incomeAndExpanseStatistics',
            meta: {
              name: '收支统计',
              href: '/financialAffairs/accountRecords/chart',
              crumbs: ['财务','账目记录','收支统计'],
            },
            component: () => import('@/view/page/FinancialAffairs/AccountRecords/Chart.vue')
          }
        ]
      },
      {
        path: 'invoice',
        name: 'invoice',
        meta: {
          name: '发票审核',
          crumbs: ['财务','发票审核'],
        },
        children: [
          {
            path: 'pending',
            name: 'invoicePending',
            meta: {
              name: '待处理',
              href: '/financialAffairs/invoice/pending',
              crumbs: ['财务','发票审核','待处理'],
            },
            component: () => import('@/view/page/FinancialAffairs/Invoice/Pending.vue')
          },
          {
            path: 'record',
            name: 'invoiceRecord',
            meta: {
              name: '发票记录',
              href: '/financialAffairs/invoice/record',
              crumbs: ['财务','发票审核','发票记录'],
            },
            component: () => import('@/view/page/FinancialAffairs/Invoice/Record.vue')
          }
        ]
      },
      {
        path: 'setting',
        name: 'financialSetting',
        meta: {
          name: '财务设置',
          crumbs: ['财务','财务设置'],
        },
        children: [
          {
            path: 'incomeCate',
            name: 'incomeCate',
            meta: {
              name: '收入分类',
              href: '/financialAffairs/setting/incomeCate',
              crumbs: ['财务','财务设置','收入分类'],
            },
            component: () => import('@/view/page/FinancialAffairs/Setting/IncomeCate.vue')
          },
          {
            path: 'expenditureCate',
            name: 'expenditureCate',
            meta: {
              name: '支出分类',
              href: '/financialAffairs/setting/expenditureCate',
              crumbs: ['财务','财务设置','支出分类'],
            },
            component: () => import('@/view/page/FinancialAffairs/Setting/ExpenditureCate.vue')
          },
          {
            path: '/type',
            name: 'payType',
            meta: {
              name: '支付方式',
              href: '/financialAffairs/setting/type',
              crumbs: ['财务','财务设置','支付方式'],
            },
            component: () => import('@/view/page/FinancialAffairs/Setting/Type.vue')
          },
          {
            path: 'category',
            name: 'invoiceCategory',
            meta: {
              name: '发票类目',
              href: '/financialAffairs/setting/category',
              crumbs: ['财务','财务设置','发票类目'],
            },
            component: () => import('@/view/page/FinancialAffairs/Setting/Category.vue')
          },
        ]
      },
    ]
  }
]

export default routes;